package com.ft.oa.mapper.dev;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ft.oa.domain.dev.DevAttachment;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

public interface DevAttachmentMapper extends BaseMapper<DevAttachment> {

    @Select("select project_number from exec_project where id in (\n" +
            "    select project_id\n" +
            "    from dev_need\n" +
            "    where issue_id = (select dev_need_issue_id from dev_allocate where id = ${devAllocateId})\n" +
            ")")
    String[] queryProjectNumbers(@Param("devAllocateId") Long devAllocateId);

}
